/*
 * ShoppingCartShopCarriageListItem.java
 * business
 *
 * Created by ChenTao on 2017/2/14.
 *
 * Copyright (c) 2017年 yidiandao. All rights reserved.
 */

package com.yidiandao.business.ui.widget.listview.displaylistitem;

import android.content.Context;

import com.yidiandao.business.data.bean.Shop;
import com.yidiandao.business.ui.widget.listview.DisplayListItem;
import com.yidiandao.business.ui.widget.listview.viewholder.ShoppingCartShopCarriageHolder;

/**
 * 购物车-店铺-配送方式-ListItem
 *
 * <p>Created by ChenTao(chentao7v@gmail.com) on 2017/2/14 9:21
 */
public class ShoppingCartShopCarriageListItem
        extends DisplayListItem<ShoppingCartShopCarriageHolder, Shop> {

    public ShoppingCartShopCarriageListItem(Shop s) {
        super(s);
    }

    @Override
    public void onShow(Context context, ShoppingCartShopCarriageHolder holder) {
        holder.setShopCarriage(data.getTotalLogisticsMoney());
        holder.setCarriageFreeLine(data.getLogisticsFreeMoney());
    }

    @Override
    public String getDisplayItemTag() {
        return ShoppingCartShopCarriageListItem.class.getSimpleName();
    }

    @Override
    public Class<ShoppingCartShopCarriageHolder> getViewHolderClazz() {
        return ShoppingCartShopCarriageHolder.class;
    }
}
